package com.svse.designPattern.behaviour.state.context;

import com.svse.designPattern.behaviour.state.impl.LowState;
import com.svse.designPattern.behaviour.state.service.AbstractState;

/**
 * @author LiYuhang
 * @version 0.1
 * @application
 * @Date 2020/8/8 11:19
 */
public  class ScoreContext  {
    private AbstractState abstractState;

    public ScoreContext( ) {
        this.abstractState = new LowState(this);
    }

    public AbstractState getAbstractState() {
        return abstractState;
    }

    public void setAbstractState(AbstractState abstractState) {
        this.abstractState = abstractState;
    }
    public   void add(int score){
        abstractState.addScore(score);
    }
}
